//表单校验规则
export const formRules = {
    username: [{
        required: true,
        message: '用户名 必填'
    }],
    nickname: [{
        required: true,
        message: '姓名 必填'
    }],
    password: [{
        required: true,
        message: '密码 必填'
    }],
    email: [{
        required: true,
        message: '邮箱 必填'
    }],
    phone: [{
        required: true,
        message: '手机号 必填'
    }]

};

//表单model
export function formModel(
    username = null,
    nickname = null,
    password = null,
    email = null,
    phone = null,
    avatar = null
    ) {
    this.username = username
    this.nickname = nickname
    this.password = password
    this.email = email
    this.phone = phone
    this.avatar = avatar
}

//表头搜索
export function filterModel(
    username = null,
    nickname = null,
    email = null,
    phone = null,
    status = null,
) {
    this.username = username
    this.nickname = nickname
    this.email = email
    this.phone = phone
    this.status = status
}
